package com.imooc.imoocbilibili.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
import com.imooc.imoocbilibili.mapper.VideoCollectionMapper;
import com.imooc.imoocbilibili.entity.VideoCollection;
import com.imooc.imoocbilibili.service.VideoCollectionService;

@Service("videoCollectionService")
@RequiredArgsConstructor
public class VideoCollectionServiceImpl extends ServiceImpl<VideoCollectionMapper, VideoCollection> implements VideoCollectionService {

    @Override
    public Page<VideoCollection> queryPage(Integer pageNo, Integer pageSize) {
        Page<VideoCollection> page = this.page(
                new Page<>(pageNo, pageSize),
                // 拼接查询条件
                new LambdaQueryWrapper<VideoCollection>()
        );

        return page;
    }

}